package zhaolongli_Entity;

import java.util.Scanner;

import zhaolongli_Boundary.Application;


public class Driver {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		int numN = 0;
		int numM = 0;
		String question;
		
		Scanner sc = new Scanner (System.in);
		
		/** get input for user about the question */
		System.out.println("Enter the Question of the Decision Lines");		
		question = (sc.nextLine());
		
		/** get input from user to set N and M, must be integer between 3 to 8 */
		
		while(numN<3 || numN>8){
			System.out.println("Enter number of CHOICES (between 3 to 8)");
			try{
				numN = Integer.valueOf(sc.nextLine());
			}catch(NumberFormatException ex){
				System.out.println("Must enter integer between 3 to 8 for number of choice");
				continue;
			}		
		}
		
		while(numM<3 || numM >8){
			System.out.println("Enter number of ROUNDS (between 3 to 8)");
			try{
				numM = Integer.valueOf(sc.nextLine());
			}catch(NumberFormatException ex){
				System.out.println("Must enter integer between 3 to 8 for number of rounds");
				continue;
			}		
		}
		
		
		Model m = new Model(numN, numM);
		m.setQuestion(question);
		Application mainPanel = new Application(m);
		mainPanel.setVisible(true);
				
	}

}
